﻿
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace App
{
    using ECommon.Components;
    using ECommon.Utilities;
    using ENode.Commanding;

    class Program
    {
        static void Main(string[] args)
        {
            Bootstrap.Initialize();
            Bootstrap.Start();

            var commandService = ObjectContainer.Resolve<ICommandService>();


            while (true)
            {
                Console.WriteLine("Press Enter Name...");
                string input = Console.ReadLine();
                if (input == "exit")
                {
                    break;
                }

                var noteId = ObjectId.GenerateNewStringId();
                var command1 = new Commands.Accounts.RegisterNewAccountCommand(noteId, input + noteId, "pwd");
                commandService.Send(command1);

            }
            Console.WriteLine("Press Enter to exit...");
            Console.ReadLine();

        }
    }
}
